package com.appkubes.mall.core.pojo;

import com.appkubes.mall.core.po.MallKd;
import com.appkubes.mall.core.po.MallKdExample;
import java.util.List;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.DeleteProvider;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.InsertProvider;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.SelectProvider;
import org.apache.ibatis.annotations.Update;
import org.apache.ibatis.annotations.UpdateProvider;
import org.apache.ibatis.session.RowBounds;
import org.apache.ibatis.type.JdbcType;

public interface MallKdMapper {
    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @SelectProvider(type=MallKdSqlProvider.class, method="countByExample")
    long countByExample(MallKdExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @DeleteProvider(type=MallKdSqlProvider.class, method="deleteByExample")
    int deleteByExample(MallKdExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @Delete({
        "delete from mall_kd",
        "where kd_key = #{kdKey,jdbcType=VARCHAR}"
    })
    int deleteByPrimaryKey(String kdKey);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @Insert({
        "insert into mall_kd (kd_key, app_key, ",
        "PushTime, EBusinessID, ",
        "LogisticCode, ShipperCode, ",
        "EstimatedDeliveryTime, `State`, ",
        "`Count`, create_time, ",
        "update_time, version, ",
        "Traces)",
        "values (#{kdKey,jdbcType=VARCHAR}, #{appKey,jdbcType=VARCHAR}, ",
        "#{pushtime,jdbcType=TIMESTAMP}, #{ebusinessid,jdbcType=VARCHAR}, ",
        "#{logisticcode,jdbcType=VARCHAR}, #{shippercode,jdbcType=VARCHAR}, ",
        "#{estimateddeliverytime,jdbcType=TIMESTAMP}, #{state,jdbcType=TINYINT}, ",
        "#{count,jdbcType=INTEGER}, #{createTime,jdbcType=INTEGER}, ",
        "#{updateTime,jdbcType=INTEGER}, #{version,jdbcType=INTEGER}, ",
        "#{traces,jdbcType=LONGVARCHAR})"
    })
    int insert(MallKd record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @InsertProvider(type=MallKdSqlProvider.class, method="insertSelective")
    int insertSelective(MallKd record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @SelectProvider(type=MallKdSqlProvider.class, method="selectByExampleWithBLOBs")
    @Results({
        @Result(column="kd_key", property="kdKey", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="app_key", property="appKey", jdbcType=JdbcType.VARCHAR),
        @Result(column="PushTime", property="pushtime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="EBusinessID", property="ebusinessid", jdbcType=JdbcType.VARCHAR),
        @Result(column="LogisticCode", property="logisticcode", jdbcType=JdbcType.VARCHAR),
        @Result(column="ShipperCode", property="shippercode", jdbcType=JdbcType.VARCHAR),
        @Result(column="EstimatedDeliveryTime", property="estimateddeliverytime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="State", property="state", jdbcType=JdbcType.TINYINT),
        @Result(column="Count", property="count", jdbcType=JdbcType.INTEGER),
        @Result(column="create_time", property="createTime", jdbcType=JdbcType.INTEGER),
        @Result(column="update_time", property="updateTime", jdbcType=JdbcType.INTEGER),
        @Result(column="version", property="version", jdbcType=JdbcType.INTEGER),
        @Result(column="Traces", property="traces", jdbcType=JdbcType.LONGVARCHAR)
    })
    List<MallKd> selectByExampleWithBLOBsWithRowbounds(MallKdExample example, RowBounds rowBounds);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @SelectProvider(type=MallKdSqlProvider.class, method="selectByExampleWithBLOBs")
    @Results({
        @Result(column="kd_key", property="kdKey", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="app_key", property="appKey", jdbcType=JdbcType.VARCHAR),
        @Result(column="PushTime", property="pushtime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="EBusinessID", property="ebusinessid", jdbcType=JdbcType.VARCHAR),
        @Result(column="LogisticCode", property="logisticcode", jdbcType=JdbcType.VARCHAR),
        @Result(column="ShipperCode", property="shippercode", jdbcType=JdbcType.VARCHAR),
        @Result(column="EstimatedDeliveryTime", property="estimateddeliverytime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="State", property="state", jdbcType=JdbcType.TINYINT),
        @Result(column="Count", property="count", jdbcType=JdbcType.INTEGER),
        @Result(column="create_time", property="createTime", jdbcType=JdbcType.INTEGER),
        @Result(column="update_time", property="updateTime", jdbcType=JdbcType.INTEGER),
        @Result(column="version", property="version", jdbcType=JdbcType.INTEGER),
        @Result(column="Traces", property="traces", jdbcType=JdbcType.LONGVARCHAR)
    })
    List<MallKd> selectByExampleWithBLOBs(MallKdExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @SelectProvider(type=MallKdSqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="kd_key", property="kdKey", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="app_key", property="appKey", jdbcType=JdbcType.VARCHAR),
        @Result(column="PushTime", property="pushtime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="EBusinessID", property="ebusinessid", jdbcType=JdbcType.VARCHAR),
        @Result(column="LogisticCode", property="logisticcode", jdbcType=JdbcType.VARCHAR),
        @Result(column="ShipperCode", property="shippercode", jdbcType=JdbcType.VARCHAR),
        @Result(column="EstimatedDeliveryTime", property="estimateddeliverytime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="State", property="state", jdbcType=JdbcType.TINYINT),
        @Result(column="Count", property="count", jdbcType=JdbcType.INTEGER),
        @Result(column="create_time", property="createTime", jdbcType=JdbcType.INTEGER),
        @Result(column="update_time", property="updateTime", jdbcType=JdbcType.INTEGER),
        @Result(column="version", property="version", jdbcType=JdbcType.INTEGER)
    })
    List<MallKd> selectByExampleWithRowbounds(MallKdExample example, RowBounds rowBounds);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @SelectProvider(type=MallKdSqlProvider.class, method="selectByExample")
    @Results({
        @Result(column="kd_key", property="kdKey", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="app_key", property="appKey", jdbcType=JdbcType.VARCHAR),
        @Result(column="PushTime", property="pushtime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="EBusinessID", property="ebusinessid", jdbcType=JdbcType.VARCHAR),
        @Result(column="LogisticCode", property="logisticcode", jdbcType=JdbcType.VARCHAR),
        @Result(column="ShipperCode", property="shippercode", jdbcType=JdbcType.VARCHAR),
        @Result(column="EstimatedDeliveryTime", property="estimateddeliverytime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="State", property="state", jdbcType=JdbcType.TINYINT),
        @Result(column="Count", property="count", jdbcType=JdbcType.INTEGER),
        @Result(column="create_time", property="createTime", jdbcType=JdbcType.INTEGER),
        @Result(column="update_time", property="updateTime", jdbcType=JdbcType.INTEGER),
        @Result(column="version", property="version", jdbcType=JdbcType.INTEGER)
    })
    List<MallKd> selectByExample(MallKdExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @Select({
        "select",
        "kd_key, app_key, PushTime, EBusinessID, LogisticCode, ShipperCode, EstimatedDeliveryTime, ",
        "`State`, `Count`, create_time, update_time, version, Traces",
        "from mall_kd",
        "where kd_key = #{kdKey,jdbcType=VARCHAR}"
    })
    @Results({
        @Result(column="kd_key", property="kdKey", jdbcType=JdbcType.VARCHAR, id=true),
        @Result(column="app_key", property="appKey", jdbcType=JdbcType.VARCHAR),
        @Result(column="PushTime", property="pushtime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="EBusinessID", property="ebusinessid", jdbcType=JdbcType.VARCHAR),
        @Result(column="LogisticCode", property="logisticcode", jdbcType=JdbcType.VARCHAR),
        @Result(column="ShipperCode", property="shippercode", jdbcType=JdbcType.VARCHAR),
        @Result(column="EstimatedDeliveryTime", property="estimateddeliverytime", jdbcType=JdbcType.TIMESTAMP),
        @Result(column="State", property="state", jdbcType=JdbcType.TINYINT),
        @Result(column="Count", property="count", jdbcType=JdbcType.INTEGER),
        @Result(column="create_time", property="createTime", jdbcType=JdbcType.INTEGER),
        @Result(column="update_time", property="updateTime", jdbcType=JdbcType.INTEGER),
        @Result(column="version", property="version", jdbcType=JdbcType.INTEGER),
        @Result(column="Traces", property="traces", jdbcType=JdbcType.LONGVARCHAR)
    })
    MallKd selectByPrimaryKey(String kdKey);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @UpdateProvider(type=MallKdSqlProvider.class, method="updateByExampleSelective")
    int updateByExampleSelective(@Param("record") MallKd record, @Param("example") MallKdExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @UpdateProvider(type=MallKdSqlProvider.class, method="updateByExampleWithBLOBs")
    int updateByExampleWithBLOBs(@Param("record") MallKd record, @Param("example") MallKdExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @UpdateProvider(type=MallKdSqlProvider.class, method="updateByExample")
    int updateByExample(@Param("record") MallKd record, @Param("example") MallKdExample example);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @UpdateProvider(type=MallKdSqlProvider.class, method="updateByPrimaryKeySelective")
    int updateByPrimaryKeySelective(MallKd record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @Update({
        "update mall_kd",
        "set app_key = #{appKey,jdbcType=VARCHAR},",
          "PushTime = #{pushtime,jdbcType=TIMESTAMP},",
          "EBusinessID = #{ebusinessid,jdbcType=VARCHAR},",
          "LogisticCode = #{logisticcode,jdbcType=VARCHAR},",
          "ShipperCode = #{shippercode,jdbcType=VARCHAR},",
          "EstimatedDeliveryTime = #{estimateddeliverytime,jdbcType=TIMESTAMP},",
          "`State` = #{state,jdbcType=TINYINT},",
          "`Count` = #{count,jdbcType=INTEGER},",
          "create_time = #{createTime,jdbcType=INTEGER},",
          "update_time = #{updateTime,jdbcType=INTEGER},",
          "version = #{version,jdbcType=INTEGER},",
          "Traces = #{traces,jdbcType=LONGVARCHAR}",
        "where kd_key = #{kdKey,jdbcType=VARCHAR}"
    })
    int updateByPrimaryKeyWithBLOBs(MallKd record);

    /**
     * This method was generated by MyBatis Generator.
     * This method corresponds to the database table mall_kd
     *
     * @mbg.generated
     */
    @Update({
        "update mall_kd",
        "set app_key = #{appKey,jdbcType=VARCHAR},",
          "PushTime = #{pushtime,jdbcType=TIMESTAMP},",
          "EBusinessID = #{ebusinessid,jdbcType=VARCHAR},",
          "LogisticCode = #{logisticcode,jdbcType=VARCHAR},",
          "ShipperCode = #{shippercode,jdbcType=VARCHAR},",
          "EstimatedDeliveryTime = #{estimateddeliverytime,jdbcType=TIMESTAMP},",
          "`State` = #{state,jdbcType=TINYINT},",
          "`Count` = #{count,jdbcType=INTEGER},",
          "create_time = #{createTime,jdbcType=INTEGER},",
          "update_time = #{updateTime,jdbcType=INTEGER},",
          "version = #{version,jdbcType=INTEGER}",
        "where kd_key = #{kdKey,jdbcType=VARCHAR}"
    })
    int updateByPrimaryKey(MallKd record);
}